<?php
namespace Home\Controller;
use Think\Controller\RestController;
class MemberlistController extends RestController {
    public function index(){
        $log=M('action_log');
        $test=$log->select();
        //var_dump($test);
       /* $res=array(array('username'=>'Admin','department'=>'网络营销部','reg_datetime'=>'2016年3月2日15:00:53'));
        $this->response($res,'json');*/
        foreach ($test as $v) {
           if ($v['status']==1) {
               $v['status']='管理员';
           }
           $res[]=$v;
        }
        var_dump($res);
        //$this->response($test,'json');
    }
}